<%@ page import="java.util.*"%>
<%@ page import="gmusic.bo.ArtistBean"%>
<%@ page import="gmusic.bo.ReleaseBean"%>
<%@ page import="gmusic.bo.TrackBean"%>
<jsp:include page="include/entete.jsp" flush="true">
	<jsp:param name="titre" value="Groupes Metal Archives" />
	<jsp:param name="sousTitre" value="Liste des groupes" />
</jsp:include>

<%
	List<ArtistBean> artists = (List<ArtistBean>) session
			.getAttribute("artists");
	List<ReleaseBean> releases = (List<ReleaseBean>) session
			.getAttribute("releases");
	List<TrackBean> tracks = (List<TrackBean>) session
			.getAttribute("tracks");
%>

<!-- Affichage des artistes -->
<div class="table">
<table width="100%" border="0">
	<thead>
		<tr class="thead">
			<th colspan="2">Artistes</th>
		</tr>
	</thead>
	<tfoot>
		<tr class="tfoot">
			<td colspan="5"><%=artists.size()%> enregistrement(s)</td>
		</tr>
	</tfoot>
	<tbody>
		<%
			String[] ligneCouleur = new String[] { "ligne1", "ligne2" };
			for (int i = 0; i < artists.size(); i++) {
		%>
		<tr class="<%=ligneCouleur[i % 2]%>">
			<td class="id">[<%=artists.get(i).getGmid()%>]</td>
			<td><a
				href="AfficherAlbums.gm?idGroupe=<%=artists.get(i).getGmid()%>"><%=artists.get(i).getNom()%></a>
				<% if (artists.get(i).getMaid() != 0) { %>
				<a href="AfficherReleasesMA.gm?maid=<%=artists.get(i).getMaid()%>">(MA)</a>
				<% } %>
			</td>
		</tr>
		<%
			}
		%>
	</tbody>
</table>
</div>

<!-- Affichage des releases -->
<div class="table">
<table width="100%" border="0">
	<thead>
		<tr class="thead">
			<th colspan="2">Releases</th>
		</tr>
	</thead>
	<tfoot>
		<tr class="tfoot">
			<td colspan="5"><%=releases.size()%> enregistrement(s)</td>
		</tr>
	</tfoot>
	<tbody>
		<%
			for (int i = 0; i < releases.size(); i++) {
		%>
		<tr class="<%=ligneCouleur[i % 2]%>">
			<td class="id">[<%=releases.get(i).getGmid()%>]</td>
			<td><a
				href="AfficherReleaseTracks.gm?rgmid=<%=releases.get(i).getGmid()%>"><%=releases.get(i).getNom()%></a></td>
		</tr>
		<%
			}
		%>
	</tbody>
</table>
</div>

<!-- Affichage des titres -->
<div class="table">
<table width="100%" border="0">
	<thead>
		<tr class="thead">
			<th colspan="2">Titres</th>
		</tr>
	</thead>
	<tfoot>
		<tr class="tfoot">
			<td colspan="5"><%=tracks.size()%> enregistrement(s)</td>
		</tr>
	</tfoot>
	<tbody>
		<%
			for (int i = 0; i < tracks.size(); i++) {
		%>
		<tr class="<%=ligneCouleur[i % 2]%>">
			<td class="id">[<%=tracks.get(i).getGmid()%>]</td>
			<td><a
				href="AfficherReleaseTracks.gm?tgmid=<%=tracks.get(i).getGmid()%>"><%=tracks.get(i).getNom()%></a></td>
		</tr>
		<%
			}
		%>
	</tbody>
</table>
</div>

<jsp:include page="include/piedPage.jsp" flush="true" />